package com.wulijie.command;

/**
 * @Author cui
 * @Data
 */
public class CommandClient {
    public static void main(String[] args) {
        CommandReceiver receiver = new CommandReceiver();
        OnCommand onCommand = new OnCommand(receiver);
        OffCommand offCommand = new OffCommand(receiver);

        RemoteHandle handle = new RemoteHandle();
        handle.setCommand(0, onCommand, offCommand);

        handle.buttonOnPush(0);
        handle.undo();

        handle.buttonOffPush(0);
        handle.undo();

    }
}
